<?php  
/**
* View of the module of registration
* Отображение модуля регистрации
* @author IT studio IRBIS-team
* @copyright © 2009 IRBIS-team
*/
/////////////////////////////////////////////////////////

/**
* Generation of page of an error at access out of system
* Генерация страницы ошибки при доступе вне системы
*/
    if(!defined('IRB_KEY'))
    {
       header("HTTP/1.1 404 Not Found");      
       exit(file_get_contents('../../404.html'));
    }    
///////////////////////////////////////////////////////////

    $POST      = htmlChars($POST);
	$GET['id'] = !empty($GET['id'])?htmlChars($GET['id']):'';
/** 
* The switch of templates
* Переключатель шаблонов
*/
    switch($GET['rem'])
	{
	    case 'registration':
            include './skins/tpl/register/show.tpl';;
		break;
		
	    case 'activate':
 	        include './skins/tpl/register/form_activate.tpl';
		break;
				
	    case 'enter':
 	        include './skins/tpl/register/form_autorize.tpl';
		break;
				
	    case 'office':
 	        include './skins/tpl/register/form_office.tpl';
		break;
		
	    case 'restoration':
		    if(!$error || !empty($GET['id']))
 	            include './skins/tpl/register/form_activate.tpl';
			else
 	            include './skins/tpl/register/form_restoration.tpl';			
		break;
						
		default:
			include './skins/tpl/register/form_autorize.tpl';
	}	

